#! /bin/sh
# auto-correlation
# Authors: Dave, Jack
# NOTE: Comment lines preceeding user input start with  #!#
set -x

#!# set parameters
panel=cdp601to610
cdpmin=601
cdpmax=610
fold=30

### compute spacing corresponding to number of offsets in the cdp gather
d2=`bc -l <<-END
	scale=4
	1/$fold
END`

### autocorrelate the cmp's after gaining by t
### X Windows version
sugain <$panel tpow=1 |
suacor norm=1 |
suximage f2=$cdpmin d2=$d2 \
	label1="Time (sec)" title="Autocorr of CMPs $cdpmin to $cdpmax" \
	perc=99 grid1=solid &


exit

### PostScript version
sugain <$panel tpow=1 |
suacor norm=1 |
supsimage f2=$cdpmin d2=$d2 \
	label1="Time (sec)" title="Autocorr of CMPs $cdpmin to $cdpmax" \
	perc=99 grid1=solid | open
